#
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

DEPTH = ../../../../..
topsrcdir = @top_srcdir@
srcdir = @srcdir@
VPATH = @srcdir@

include $(DEPTH)/config/autoconf.mk

MODULE = xpctest
LIBRARY_NAME = xpctest
IS_COMPONENT = 1
MODULE_NAME = xpconnect_test
NO_DIST_INSTALL = 1

JS_FILES = \
  xpctest_attributes.js \
  xpctest_interfaces.js \
  xpctest_params.js \
  $(NULL)

include $(topsrcdir)/config/config.mk

MANIFEST_FILE = xpctest.manifest

include $(topsrcdir)/config/rules.mk

componentdir = js/xpconnect/tests/components/js

libs:: $(JS_FILES)
	$(INSTALL) $^ $(testxpcobjdir)/$(componentdir)

libs:: $(MANIFEST_FILE)
	$(PYTHON) $(topsrcdir)/config/Preprocessor.py $(DEFINES) $(ACDEFINES) $(XULPPFLAGS) $< > $(testxpcobjdir)/$(componentdir)/$(<F)
